import { Map }  from 'immutable'
// 对象  Map
// 数组  List
const initialState = Map({
  bannerList: [],
  proList: []
})
const reducer = (state = initialState, { type, payload}) => {
  console.log('222', payload)
  switch (type) {
    case 'CHANGE_BANNER_LIST':
      console.log('333', payload)
      // return {...state, bannerList: payload}
      return state.set('bannerList', payload)
    case 'CHANGE_PRO_LIST':
      return state.set('proList', payload)
      // return {...state, proList: payload}
    default:
      return state;
  }
}

export default reducer